<?php
/**
 * @TABLE "user_message"
 * @JOIN_FROM "user_from_id < user.id"
 * @JOIN_FROM "user_to_id < user.id"
 */
class BaseUserMessage extends Abstract_PluginEntityManager_Entity
{
	/**
	 * @PRIMARY
	 * @COLUMN "id"
	 * @TYPE "int"
	 * @LENGTH "10"
	 * @NOT_NULL
	 * @AUTO_INCREMENT
	 */
	public $id;

	/**
	 * @COLUMN "type"
	 * @TYPE "enum"
	 * @LENGTH "'message','friend_request'"
	 * @NOT_NULL
	 * @DEFAULT "message"
	 */
	public $type;

	/**
	 * @COLUMN "user_from_id"
	 * @TYPE "int"
	 * @LENGTH "10"
	 * @NOT_NULL
	 */
	public $user_from_id;

	/**
	 * @COLUMN "user_to_id"
	 * @TYPE "int"
	 * @LENGTH "10"
	 * @NOT_NULL
	 */
	public $user_to_id;

	/**
	 * @COLUMN "rel_id"
	 * @TYPE "int"
	 * @LENGTH "10"
	 */
	public $rel_id;

	/**
	 * @COLUMN "date_added"
	 * @TYPE "timestamp"
	 * @NOT_NULL
	 * @DEFAULT "CURRENT_TIMESTAMP"
	 */
	public $date_added;

	/**
	 * @COLUMN "read_from"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "1"
	 */
	public $read_from;

	/**
	 * @COLUMN "read_to"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "0"
	 */
	public $read_to;

	/**
	 * @COLUMN "trash_from"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "0"
	 */
	public $trash_from;

	/**
	 * @COLUMN "trash_to"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "0"
	 */
	public $trash_to;

	/**
	 * @COLUMN "deleted_from"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "0"
	 */
	public $deleted_from;

	/**
	 * @COLUMN "deleted_to"
	 * @TYPE "tinyint"
	 * @LENGTH "1"
	 * @NOT_NULL
	 * @DEFAULT "0"
	 */
	public $deleted_to;

	/**
	 * @COLUMN "subject"
	 * @TYPE "varchar"
	 * @LENGTH "128"
	 */
	public $subject;

	/**
	 * @COLUMN "message"
	 * @TYPE "varchar"
	 * @LENGTH "512"
	 */
	public $message;
}
?>